<?php
/**
 * Magento
 *
 * NOTICE OF LICENSE
 *
 * This source file is subject to the Academic Free License (AFL 3.0)
 * that is bundled with this package in the file LICENSE_AFL.txt.
 * It is also available through the world-wide-web at this URL:
 * http://opensource.org/licenses/afl-3.0.php
 * If you did not receive a copy of the license and are unable to
 * obtain it through the world-wide-web, please send an email
 * to license@magentocommerce.com so we can send you a copy immediately.
 *
 * DISCLAIMER
 *
 * Do not edit or add to this file if you wish to upgrade Magento to newer
 * versions in the future. If you wish to customize Magento for your
 * needs please refer to http://www.magentocommerce.com for more information.
 *
 * @category    design
 * @package     base_default
 * @copyright   Copyright (c) 2010 Magento Inc. (http://www.magentocommerce.com)
 * @license     http://opensource.org/licenses/afl-3.0.php  Academic Free License (AFL 3.0)
 */
/**
 * @var Mage_Page_Block_Html_Header $this
 */
?>
<div class="header-container">
    <div class="header">
        <?php if ($this->getIsHomePage()):?>
        <h1 class="logo"><strong><?php echo $this->getLogoAlt() ?></strong><a href="<?php echo $this->getUrl('') ?>" title="<?php echo $this->getLogoAlt() ?>" class="logo"><img src="<?php echo $this->getLogoSrc() ?>" alt="<?php echo $this->getLogoAlt() ?>" /></a></h1>
        <?php else:?>
        <a href="<?php echo $this->getUrl('') ?>" title="<?php echo $this->getLogoAlt() ?>" class="logo"><strong><?php echo $this->getLogoAlt() ?></strong><img src="<?php echo $this->getLogoSrc() ?>" alt="<?php echo $this->getLogoAlt() ?>" /></a>
        <?php endif?>
        <!--<div class="quick-access">
            
            <p class="welcome-msg"><?php echo $this->getWelcome()?></p>
            <?php echo $this->getChildHtml('topLinks') ?>
            <?php echo $this->getChildHtml('store_language') ?>
        </div>-->
        <?php //echo $this->getChildHtml('topContainer'); 
		$cart = Mage::helper('checkout/cart')->getCart()->getItemsCount();
		$total_amount = Mage::getSingleton('checkout/session')->getQuote()->getGrandTotal();
		
		 
		$formatted_price = Mage::helper('core')->currency($total_amount);
		?>
        <div id="yourbasket">
			<h2>Your Basket</h2>
			<p>You have <?php echo $cart; ?> Items in your basket |  <?php echo $formatted_price; ?></p>
			<ul>
				<li><a href="<?php echo $this->getUrl('') ?>checkout/cart/" title="View Basket" class="viewbasket">&nbsp;</a></li>
				<li><a href="<?php echo $this->getUrl('') ?>checkout/onepage/" title="Checkout" class="checkout">&nbsp;</a></li>
			</ul>
		</div>
		<div id="youraccount">
		
			<h2>Your Account</h2>
			<?php
			  if(Mage::getSingleton('customer/session')->isLoggedIn()){
			    ?>			
		
			<p>Welcome back <strong><?php echo Mage::getSingleton('customer/session')->getCustomer()->getName() ;?></strong></p>
			<ul>
				<li><a href="<?php echo $this->getUrl('') ?>sales/order/history" title="View Order Status" class="orderstatus">&nbsp;</a></li>
				<li><a href="<?php echo $this->getUrl('') ?>customer/account/edit/" title="Update Your Account Details" class="edityourdetails">&nbsp;</a></li>
				<li><a href="<?php echo $this->getUrl('') ?>customer/account/logout" title="Logout" class="logout">&nbsp;</a></li>
			</ul>
		
				
				<?php
			  
			  }else{				
		  ?>
		  
		  
			<p>Returning shopper?</p>
			<ul>
				<li><a href="<?php echo $this->getUrl('') ?>customer/account/login/" title="Login" class="login">&nbsp;</a></li>
			</ul>
		  <?php } ?>	
		</div>
    </div>
</div>
<div id="topnav">
<div id="searchbox"> <?php echo $this->getChildHtml('topSearch') ?>
</div>  
<?php

 
$current_page_arr = explode("/",$_SERVER[REQUEST_URI]);
$key = count($current_page_arr)-2;
$current_page = $current_page_arr[$key];
 
  

?>
<ul>
<li<?php if ($current_page == "" || $current_page == "index.php"  ):?>
  id="active-lv1" <?php endif?>><a href="<?php echo $this->getUrl('') ?>" title="Go to the Shop Homepage">Shop Home</a></li>
<li<?php if ( $current_page == "about-us" ):?>
	id="active-lv1"    <?php endif?> > <a href="<?php echo $this->getUrl('about-us') ?>" title="About Us">About Us</a></li>
<li<?php if ($current_page == "delivery" ):?>
	id="active-lv1"   <?php endif?>><a href="<?php echo $this->getUrl('delivery') ?>" title="Delivery">Delivery</a></li >
<li<?php if ($current_page == "contacts" ):?>
	id="active-lv1" <?php endif?>><a href="<?php echo $this->getUrl('contacts') ?>" title="Contact Us">Contact Us</a></li>
<li><a href="http://www.blackburncathedral.com/" title="Visit BlackburnCathedral.com" target="_blank">Visit BlackburnCathedral.com</a></li>
</ul>
</div>
